1. Field of the Invention
The present invention relates to flashing and reading a non-volatile memory, and more particularly to flashing and reading a read-only memory of a computer system independently of its operating system.
2. Description of the Related Art
Access to flash ROM devices in a computer system is increasingly being safeguarded by software and/or hardware protection and virtualization mechanisms. Such mechanisms, which range from block locking and write protection to password protection and secure memory devices, may be traversed by devices having the necessary privilege level. In a computer system, an application is typically given the lowest privilege level. An application requiring direct access to a flash ROM device, such as software for flashing a ROM image or for reading a version of a ROM, thus must be able to direct a device having the necessary privilege level to release security protection for the flash ROM device. Similarly, access to certain areas of a memory space of a computer system, such as high regions of memory where critical code is often stored, has required a particular privilege level.
Software for flashing a ROM image or for reading a version of a ROM has traditionally relied upon a driver to obtain a privilege level necessary to release any security protection for a flash ROM device and to access certain areas of a memory space. Drivers (also called device drivers), which generally serve to link a peripheral device to an operating system, are commonly used in programming and reading flash ROM devices in a computer system. In particular, a driver is typically used to control command and status registers of a flash ROM device for erasing, writing, or reading the device. Various types of information may be read from a flash ROM device, such as status data, ROM version data, device identification data, or a ROM image. Accessing a flash ROM device to read or write data has occurred exclusively in an operating system environment.
Accessing a flash ROM device in an operating system environment, however, has required updates to drivers for each hardware and operating system environment in which access to a flash ROM device is desired. Such updates, for example, may account for definitions of new bus interface standards and new memory standards. Drivers are also frequently updated to handle new ROM versions of application software, new device identification codes, or new memory size boundaries. It has been necessary, therefore, to match maintenance of a driver for accessing a flash ROM device with the frequency of changes in the hardware environment of the flash ROM device, the operating system environment, and ROM versions.
Most of today's computer systems provide an operating state known as a protected mode which supports advanced features. A protected mode has provided hardware support for multitasking and virtual memory management. At certain times in a protected mode, however, an operating system has been unable to grant a driver the privilege level necessary to release security protection for a flash ROM device. An application thus has not been guaranteed access to a flash ROM device when a computer system is in a protected mode.